<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="An enterprise-class UI design language and React-based implementation with a set of high-quality React components, one of best React UI library for enterprises">
    <title>Ant Design - A UI Design Language</title>
    <link rel="icon" href="https://gw.alipayobjects.com/zos/rmsportal/rlpTLlbMzTNYuZGGCVYM.png" type="image/x-icon">
    <link rel="stylesheet" type="text/css" href="/index-1.css"/>
    <link rel="stylesheet" type="text/css" href="/index-2.css"/>
    <style id="nprogress-style">
      #nprogress { display: none }
    </style>
    <link rel="stylesheet/less" type="text/css" href="/color.less"/>
    <script src="https://gw.alipayobjects.com/os/lib/??es6-shim/0.35.3/es6-sham.min.js,es6-shim/0.35.3/es6-shim.min.js"></script>
    <!--[if lte IE 10]>
    <script src="https://as.alipayobjects.com/g/component/??console-polyfill/0.2.2/index.js,media-match/2.0.2/media.match.min.js"></script>
    <![endif]-->
    <script>
    if (!window.Intl) {
      document.writeln('<script src="https://as.alipayobjects.com/g/component/intl/1.0.1/??Intl.js,locale-data/jsonp/en.js,locale-data/jsonp/zh.js">' + '<' + '/script>');
    }
    </script>
    <script>
    (function() {
      function isLocalStorageNameSupported() {
        var testKey = 'test';
        var storage = window.localStorage;
        try {
          storage.setItem(testKey, '1');
          storage.removeItem(testKey);
          return true;
        } catch (error) {
          return false;
        }
      }
      // 优先级提高到所有静态资源的前面，语言不对，加载其他静态资源没意义
      var pathname = location.pathname;

      function isZhCN(pathname) {
        return /-cn\/?$/.test(pathname);
      }
      function getLocalizedPathname(path, zhCN) {
        var pathname = path.startsWith('/') ? path : '/' + path;
        if (!zhCN) { // to enUS
          return /\/?index-cn/.test(pathname) ? '/' : pathname.replace('-cn', '');
        } else if (pathname === '/') {
          return '/index-cn';
        } else if (pathname.endsWith('/')) {
          return pathname.replace(/\/$/, '-cn/');
        }
        return pathname + '-cn';
      }

      // 兼容旧的 URL， `?locale=...`
      var queryString = location.search;
      if (queryString) {
        var isZhCNConfig = queryString.indexOf('zh-CN') > -1;
        if (isZhCNConfig && !isZhCN(pathname)) {
          location.pathname = getLocalizedPathname(pathname, isZhCNConfig)
        }
      }

      // 首页无视链接里面的语言设置 https://github.com/ant-design/ant-design/issues/4552
      if (isLocalStorageNameSupported() && (pathname === '/' || pathname === '/index-cn')) {
        var lang = (window.localStorage && localStorage.getItem('locale')) || ((navigator.language || navigator.browserLanguage).toLowerCase() === 'zh-cn' ? 'zh-CN' : 'en-US');
        // safari is 'zh-cn', while other browser is 'zh-CN';
        if ((lang === 'zh-CN') !== isZhCN(pathname)) {
          location.pathname = getLocalizedPathname(pathname, lang === 'zh-CN');
        }
      }
      document.documentElement.className += isZhCN(pathname) ? 'zh-cn' : 'en-us';
    })()
    </script>
  </head>
  <body>
    <div id="react-content">
      <div class="page-wrapper"><header id="header" class="clearfix"><div class="ant-row"><div class="ant-col-xs-24 ant-col-sm-24 ant-col-md-6 ant-col-lg-5 ant-col-xl-5 ant-col-xxl-4"><a id="logo" href="/"><img alt="logo" src="https://gw.alipayobjects.com/zos/rmsportal/KDpgvguMpGfqaHPjicRK.svg"/><img alt="Ant Design" src="https://gw.alipayobjects.com/zos/rmsportal/DkKNubTaaVsKURhcVGkh.svg"/></a></div><div class="ant-col-xs-0 ant-col-sm-0 ant-col-md-18 ant-col-lg-19 ant-col-xl-19 ant-col-xxl-20"><div id="search-box"><i class="anticon anticon-search"><svg viewBox="64 64 896 896" class="" data-icon="search" width="1em" height="1em" fill="currentColor" aria-hidden="true"><path d="M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0 0 11.6 0l43.6-43.5a8.2 8.2 0 0 0 0-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z"></path></svg></i><input type="text" placeholder="Search in ant.design" class="ant-input"/></div><button type="button" class="ant-btn header-lang-button ant-btn-sm ant-btn-background-ghost"><span>中文</span></button><div class="ant-select-sm version ant-select ant-select-enabled"><div class="ant-select-selection
            ant-select-selection--single" role="combobox" aria-autocomplete="list" aria-haspopup="true" aria-expanded="false" tabindex="0"><div class="ant-select-selection__rendered"><div class="ant-select-selection-selected-value" title="3.10.3" style="display:block;opacity:1">3.10.3</div></div><span class="ant-select-arrow" style="user-select:none;-webkit-user-select:none" unselectable="on"><i class="anticon anticon-down ant-select-arrow-icon"><svg viewBox="64 64 896 896" class="" data-icon="down" width="1em" height="1em" fill="currentColor" aria-hidden="true"><path d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"></path></svg></i></span></div></div><ul class="ant-menu menu-site ant-menu-light ant-menu-root ant-menu-horizontal" id="nav" role="menu"><li class="ant-menu-submenu ant-menu-submenu-horizontal ant-menu-overflowed-submenu" style="display:none" role="menuitem"><div class="ant-menu-submenu-title" aria-expanded="false" aria-haspopup="true"><span>···</span><i class="ant-menu-submenu-arrow"></i></div></li><li class="ant-menu-item" role="menuitem"><a href="/"><span>Home</span></a></li><li class="ant-menu-submenu ant-menu-submenu-horizontal ant-menu-overflowed-submenu" style="display:none" role="menuitem"><div class="ant-menu-submenu-title" aria-expanded="false" aria-haspopup="true"><span>···</span><i class="ant-menu-submenu-arrow"></i></div></li><li class="ant-menu-item" role="menuitem"><a href="/docs/spec/introduce"><span>Guidelines</span></a></li><li class="ant-menu-submenu ant-menu-submenu-horizontal ant-menu-overflowed-submenu" style="display:none" role="menuitem"><div class="ant-menu-submenu-title" aria-expanded="false" aria-haspopup="true"><span>···</span><i class="ant-menu-submenu-arrow"></i></div></li><li class="ant-menu-item ant-menu-item-selected" role="menuitem"><a href="/docs/react/introduce"><span>Components</span></a></li><li class="ant-menu-submenu ant-menu-submenu-horizontal ant-menu-overflowed-submenu" style="display:none" role="menuitem"><div class="ant-menu-submenu-title" aria-expanded="false" aria-haspopup="true"><span>···</span><i class="ant-menu-submenu-arrow"></i></div></li><li class="ant-menu-item" role="menuitem"><a href="http://pro.ant.design" class="header-link" target="_blank" rel="noopener noreferrer"><span>PRO</span></a></li><li class="ant-menu-submenu ant-menu-submenu-horizontal ant-menu-overflowed-submenu" style="visibility:hidden;position:absolute" role="menuitem"><div class="ant-menu-submenu-title" aria-expanded="false" aria-haspopup="true"><span>···</span><i class="ant-menu-submenu-arrow"></i></div></li></ul></div></div></header><div class="main-wrapper"><div class="ant-row"><div class="main-menu ant-col-xs-24 ant-col-sm-24 ant-col-md-24 ant-col-lg-6 ant-col-xl-5 ant-col-xxl-4"><ul class="ant-menu aside-container menu-site ant-menu-light ant-menu-root ant-menu-inline" role="menu"><li class="ant-menu-item" role="menuitem" style="padding-left:40px"><a href="/docs/react/introduce">Ant Design of React</a></li><li class="ant-menu-item" role="menuitem" style="padding-left:40px"><a href="/docs/react/getting-started">Getting Started</a></li><li class="ant-menu-item" role="menuitem" style="padding-left:40px"><a href="/docs/react/practical-projects">Real project with umi and dva</a></li><li class="ant-menu-item" role="menuitem" style="padding-left:40px"><a href="/docs/react/use-with-create-react-app">Use in create-react-app</a></li><li class="ant-menu-item" role="menuitem" style="padding-left:40px"><a href="/docs/react/use-in-typescript">Use in TypeScript</a></li><li class="ant-menu-item" role="menuitem" style="padding-left:40px"><a href="/docs/react/customize-theme">Customize Theme</a></li><li class="ant-menu-item" role="menuitem" style="padding-left:40px"><a href="/changelog">Change Log</a></li><li class="ant-menu-item" role="menuitem" style="padding-left:40px"><a href="/docs/react/recommendation">Third-Party Libraries</a></li><li class="ant-menu-item" role="menuitem" style="padding-left:40px"><a href="/docs/react/i18n">Internationalization</a></li><li class="ant-menu-item ant-menu-item-selected" role="menuitem" style="padding-left:40px"><a href="/docs/react/faq">FAQ</a></li><li class="ant-menu-item" role="menuitem" style="padding-left:40px"><a href="/docs/react/contributing">Contributing</a></li><li class="ant-menu-submenu ant-menu-submenu-inline ant-menu-submenu-open" role="menuitem"><div style="padding-left:40px" class="ant-menu-submenu-title" aria-expanded="true" aria-owns="Components$Menu" aria-haspopup="true"><h4>Components</h4><i class="ant-menu-submenu-arrow"></i></div><ul id="Components$Menu" class="ant-menu  ant-menu-sub ant-menu-inline" role="menu"><li class=" ant-menu-item-group"><div class="ant-menu-item-group-title" title="General">General</div><ul class="ant-menu-item-group-list"><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/button/"><span>Button</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/icon/"><span>Icon</span><span class="chinese"></span></a></li></ul></li><li class=" ant-menu-item-group"><div class="ant-menu-item-group-title" title="Layout">Layout</div><ul class="ant-menu-item-group-list"><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/grid/"><span>Grid</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/layout/"><span>Layout</span><span class="chinese"></span></a></li></ul></li><li class=" ant-menu-item-group"><div class="ant-menu-item-group-title" title="Navigation">Navigation</div><ul class="ant-menu-item-group-list"><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/affix/"><span>Affix</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/breadcrumb/"><span>Breadcrumb</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/dropdown/"><span>Dropdown</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/menu/"><span>Menu</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/pagination/"><span>Pagination</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/steps/"><span>Steps</span><span class="chinese"></span></a></li></ul></li><li class=" ant-menu-item-group"><div class="ant-menu-item-group-title" title="Data Entry">Data Entry</div><ul class="ant-menu-item-group-list"><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/auto-complete/"><span>AutoComplete</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/cascader/"><span>Cascader</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/checkbox/"><span>Checkbox</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/date-picker/"><span>DatePicker</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/form/"><span>Form</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/input/"><span>Input</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/input-number/"><span>InputNumber</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/mention/"><span>Mention</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/rate/"><span>Rate</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/radio/"><span>Radio</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/select/"><span>Select</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/slider/"><span>Slider</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/switch/"><span>Switch</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/tree-select/"><span>TreeSelect</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/time-picker/"><span>TimePicker</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/transfer/"><span>Transfer</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/upload/"><span>Upload</span><span class="chinese"></span></a></li></ul></li><li class=" ant-menu-item-group"><div class="ant-menu-item-group-title" title="Data Display">Data Display</div><ul class="ant-menu-item-group-list"><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/avatar/"><span>Avatar</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/badge/"><span>Badge</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/calendar/"><span>Calendar</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/card/"><span>Card</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/carousel/"><span>Carousel</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/collapse/"><span>Collapse</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/list/"><span>List</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/popover/"><span>Popover</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/tooltip/"><span>Tooltip</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/table/"><span>Table</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/tabs/"><span>Tabs</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/tag/"><span>Tag</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/timeline/"><span>Timeline</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/tree/"><span>Tree</span><span class="chinese"></span></a></li></ul></li><li class=" ant-menu-item-group"><div class="ant-menu-item-group-title" title="Feedback">Feedback</div><ul class="ant-menu-item-group-list"><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/alert/"><span>Alert</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/drawer/"><span>Drawer</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/modal/"><span>Modal</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/message/"><span>Message</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/notification/"><span>Notification</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/progress/"><span>Progress</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/popconfirm/"><span>Popconfirm</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/spin/"><span>Spin</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/skeleton/"><span>Skeleton</span><span class="chinese"></span></a></li></ul></li><li class=" ant-menu-item-group"><div class="ant-menu-item-group-title" title="Other">Other</div><ul class="ant-menu-item-group-list"><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/anchor/"><span>Anchor</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/back-top/"><span>BackTop</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/divider/"><span>Divider</span><span class="chinese"></span></a></li><li class="ant-menu-item" role="menuitem" style="padding-left:80px"><a href="/components/locale-provider/"><span>LocaleProvider</span><span class="chinese"></span></a></li></ul></li></ul></li></ul></div><div class="main-container ant-col-xs-24 ant-col-sm-24 ant-col-md-24 ant-col-lg-18 ant-col-xl-19 ant-col-xxl-20"><article class="markdown"><h1>FAQ<a class="edit-button" href="https://github.com/ant-design/ant-design/edit/master/docs/react/faq.en-US.md" target="_blank" rel="noopener noreferrer"><i class="anticon anticon-edit"><svg viewBox="64 64 896 896" class="" data-icon="edit" width="1em" height="1em" fill="currentColor" aria-hidden="true"><path d="M257.7 752c2 0 4-.2 6-.5L431.9 722c2-.4 3.9-1.3 5.3-2.8l423.9-423.9a9.96 9.96 0 0 0 0-14.1L694.9 114.9c-1.9-1.9-4.4-2.9-7.1-2.9s-5.2 1-7.1 2.9L256.8 538.8c-1.5 1.5-2.4 3.3-2.8 5.3l-29.5 168.2a33.5 33.5 0 0 0 9.4 29.8c6.6 6.4 14.9 9.9 23.8 9.9zm67.4-174.4L687.8 215l73.3 73.3-362.7 362.6-88.9 15.7 15.6-89zM880 836H144c-17.7 0-32 14.3-32 32v36c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-36c0-17.7-14.3-32-32-32z"></path></svg></i></a></h1><section class="markdown"><p>Search in the questions about React first: <a href="https://reactfaq.site">https://reactfaq.site</a> .</p></section><div class="toc-affix"><div class=""><ul class="toc"><li><a class="bisheng-toc-h2" href="#Errors-&amp;-Warnings" title="Errors &amp; Warnings">Errors &amp; Warnings</a></li></ul></div></div><section class="markdown"><h3 id="Are-you-going-to-provide-Vue(etc...)-edition?"><span>Are you going to provide Vue(etc...) edition?</span><a href="#Are-you-going-to-provide-Vue(etc...)-edition?" class="anchor">#</a></h3><p>No, but <a href="https://github.com/ant-design/ant-design/blob/master/LICENSE">the LICENSE of ant-design</a> is MIT. So, you can try to implement it with ant-design&#x27;s <a href="https://github.com/ant-design/ant-design/tree/master/style">style</a>, like: <a href="https://github.com/vueComponent/ant-design-vue">ant-design-vue</a> <a href="https://github.com/FE-Driver/vue-beauty">vue-beauty</a> or <a href="https://github.com/zzuu666/antue">antue</a>.</p><h3 id="Are-you-going-to-provide-Sass/Stylus(etc...)-style-file?"><span>Are you going to provide Sass/Stylus(etc...) style file?</span><a href="#Are-you-going-to-provide-Sass/Stylus(etc...)-style-file?" class="anchor">#</a></h3><p>No, actually, you can convert Less to Sass/Stylus(etc...) with tools (which you can Google).</p><h3 id="Select-Dropdown-DatePicker-TimePicker-Popover-Popconfirm-disappear-when-I-click-another-popup-component-inside-it,-How-to-resolve-it?"><span><code>Select Dropdown DatePicker TimePicker Popover Popconfirm</code> disappear when I click another popup component inside it, How to resolve it?</span><a href="#Select-Dropdown-DatePicker-TimePicker-Popover-Popconfirm-disappear-when-I-click-another-popup-component-inside-it,-How-to-resolve-it?" class="anchor">#</a></h3><p>Use <code>&lt;Select getPopupContainer={trigger =&gt; trigger.parentNode}&gt;</code> to render component inside Popover. (Or other getXxxxContainer props)</p><p><a href="https://ant.design/components/select/#Select-props">https://ant.design/components/select/#Select-props</a></p><p>related issue: <a href="https://github.com/ant-design/ant-design/issues/3487">#3487</a> <a href="https://github.com/ant-design/ant-design/issues/3438">#3438</a></p><h3 id="Select-Dropdown-DatePicker-TimePicker-Popover-Popconfirm-scroll-with-the-page?"><span><code>Select Dropdown DatePicker TimePicker Popover Popconfirm</code> scroll with the page?</span><a href="#Select-Dropdown-DatePicker-TimePicker-Popover-Popconfirm-scroll-with-the-page?" class="anchor">#</a></h3><p>Use <code>&lt;Select getPopupContainer={trigger =&gt; trigger.parentNode}&gt;</code> to render component inside the scroll area. (Or other getXxxxContainer props).</p><p><a href="https://ant.design/components/select/#Select-props">https://ant.design/components/select/#Select-props</a></p><p>related issue: <a href="https://github.com/ant-design/ant-design/issues/3487">#3487</a> <a href="https://github.com/ant-design/ant-design/issues/3438">#3438</a></p><h3 id="How-to-modify-the-default-theme-of-Ant-Design?"><span>How to modify the default theme of Ant Design?</span><a href="#How-to-modify-the-default-theme-of-Ant-Design?" class="anchor">#</a></h3><p>See: <a href="https://ant.design/docs/react/customize-theme">https://ant.design/docs/react/customize-theme</a> .</p><h3 id="Would-you-supply-other-themes?"><span>Would you supply other themes?</span><a href="#Would-you-supply-other-themes?" class="anchor">#</a></h3><p>No, we follow Ant Design specification. <a href="https://github.com/ant-design/ant-design/issues/1241">https://github.com/ant-design/ant-design/issues/1241</a></p><h3 id="How-to-modify-Menu/Button(etc...)&#x27;s-style?"><span>How to modify <code>Menu</code>/<code>Button</code>(etc...)&#x27;s style?</span><a href="#How-to-modify-Menu/Button(etc...)&#x27;s-style?" class="anchor">#</a></h3><p>You can override its style, but we don&#x27;t recommend doing so. antd is not only a set of React components but also a design specification.</p><h3 id="I-just-want-to-use-Menu/Button(etc...),-but-it-seems-that-I-have-to-import-the-whole-antd-and-its-style."><span>I just want to use <code>Menu</code>/<code>Button</code>(etc...), but it seems that I have to import the whole antd and its style.</span><a href="#I-just-want-to-use-Menu/Button(etc...),-but-it-seems-that-I-have-to-import-the-whole-antd-and-its-style." class="anchor">#</a></h3><p>Try <a href="https://github.com/ant-design/babel-plugin-import">babel-plugin-import</a>, or import what you need in this way:</p><pre class="language-jsx"><code><span class="token keyword">import</span> Menu <span class="token keyword">from</span> <span class="token string">'antd/lib/menu'</span><span class="token punctuation">;</span>
<span class="token keyword">import</span> <span class="token string">'antd/lib/button/style/css'</span><span class="token punctuation">;</span></code></pre><p>or (ES6 way with tree shaking):</p><pre class="language-jsx"><code><span class="token keyword">import</span> <span class="token punctuation">{</span> Menu<span class="token punctuation">,</span> Breadcrumb<span class="token punctuation">,</span> Icon <span class="token punctuation">}</span> <span class="token keyword">from</span> <span class="token string">'antd'</span><span class="token punctuation">;</span></code></pre><h3 id="How-to-optimize-momentjs-bundle-size-with-webpack?"><span>How to optimize momentjs bundle size with webpack?</span><a href="#How-to-optimize-momentjs-bundle-size-with-webpack?" class="anchor">#</a></h3><p>See: <a href="https://github.com/jmblog/how-to-optimize-momentjs-with-webpack">https://github.com/jmblog/how-to-optimize-momentjs-with-webpack</a></p><h3 id="It-doesn&#x27;t-work-when-I-change-defaultValue-dynamically."><span>It doesn&#x27;t work when I change <code>defaultValue</code> dynamically.</span><a href="#It-doesn&#x27;t-work-when-I-change-defaultValue-dynamically." class="anchor">#</a></h3><p>The <code>defaultXxxx</code> (like <code>defaultValue</code>) of <code>Input</code>/<code>Select</code>(etc...) only works in first render. It is a specification of React; please read <a href="https://facebook.github.io/react/docs/forms.html#controlled-components">React&#x27;s documentation</a>.</p><h3 id="I-set-the-value-of-Input/Select(etc...),-and-then,-it-cannot-be-changed-by-user&#x27;s-action."><span>I set the <code>value</code> of <code>Input</code>/<code>Select</code>(etc...), and then, it cannot be changed by user&#x27;s action.</span><a href="#I-set-the-value-of-Input/Select(etc...),-and-then,-it-cannot-be-changed-by-user&#x27;s-action." class="anchor">#</a></h3><p>Try <code>defaultValue</code> or <code>onChange</code> to change <code>value</code>, and please read <a href="https://facebook.github.io/react/docs/forms.html#controlled-components">React&#x27;s documentation</a>.</p><h3 id="antd-override-my-global-styles!"><span>antd override my global styles!</span><a href="#antd-override-my-global-styles!" class="anchor">#</a></h3><p>Yes, antd is designed to develop a complete background application, we override some global styles for styling convenience, and it can&#x27;t be removed now. More info trace <a href="https://github.com/ant-design/ant-design/issues/4331">https://github.com/ant-design/ant-design/issues/4331</a> .</p><p>Or, follow the instructions in <a href="docs/react/customize-theme#How-to-avoid-modifying-global-styles-?">How to avoid modifying global styles?</a></p><h3 id="I-cannot-install-antd-and-antd&#x27;s-dependencies(etc...).-FYI,-I-live-in-China-mainland."><span>I cannot install <code>antd</code> and <code>antd</code>&#x27;s dependencies(etc...). FYI, I live in China mainland.</span><a href="#I-cannot-install-antd-and-antd&#x27;s-dependencies(etc...).-FYI,-I-live-in-China-mainland." class="anchor">#</a></h3><p>Long live the Girl Friend Wall! And try <a href="http://npm.taobao.org/">cnpm</a>.</p><h3 id="I-set-dependencies.antd-as-git-repository-in-package.json,-but-it-doesn&#x27;t-work."><span>I set <code>dependencies.antd</code> as git repository in package.json, but it doesn&#x27;t work.</span><a href="#I-set-dependencies.antd-as-git-repository-in-package.json,-but-it-doesn&#x27;t-work." class="anchor">#</a></h3><p>Yes, please install <code>antd</code> with npm.</p><h3 id="message-and-notification-is-lower-case,-but-other-components-are-capitalized.-Typo?"><span><code>message</code> and <code>notification</code> is lower case, but other components are capitalized. Typo?</span><a href="#message-and-notification-is-lower-case,-but-other-components-are-capitalized.-Typo?" class="anchor">#</a></h3><p>No, as <code>message</code> is just a function, not a React Component.</p><h3 id="antd-doesn&#x27;t-work-well-in-mobile."><span><code>antd</code> doesn&#x27;t work well in mobile.</span><a href="#antd-doesn&#x27;t-work-well-in-mobile." class="anchor">#</a></h3><p>Please check <a href="http://mobile.ant.design">And Design Mobile</a> for details. <code>antd</code> has not been optimized to do so. You may try <a href="https://github.com/react-component/">react-component</a>, those repositories which start with &#x27;m-&#x27; &#x27;rn-&#x27; are designed for mobile.</p><h3 id="Does-antd-supply-standalone-files-like-&#x27;react&#x27;-do?"><span>Does <code>antd</code> supply standalone files like &#x27;react&#x27; do?</span><a href="#Does-antd-supply-standalone-files-like-&#x27;react&#x27;-do?" class="anchor">#</a></h3><p>Yep, you can <a href="https://ant.design/docs/react/install?locale=en-US#Import-in-Browser">import <code>antd</code> with script tag</a>. But we recommend using <code>npm</code> to import <code>antd</code>, it is simple and easy to maintain.</p><h3 id="I-can&#x27;t-visit-icon-in-my-network-environment."><span>I can&#x27;t visit <code>icon</code> in my network environment.</span><a href="#I-can&#x27;t-visit-icon-in-my-network-environment." class="anchor">#</a></h3><p>You should deploy the iconfont files to your network by following this <a href="https://github.com/ant-design/antd-init/tree/7c1a33cadb98f2fd8688fe527dd7f98215b9bced/examples/local-iconfont">example</a>. <a href="https://github.com/ant-design/ant-design/issues/1070">#1070</a></p><p>After 3.9.x <a href="/components/icon/#svg-icons">we are using svg icon</a>, so you don&#x27;t need to deploy iconfont locally anymore!</p><h3 id="How-to-extend-antd&#x27;s-components?"><span>How to extend antd&#x27;s components?</span><a href="#How-to-extend-antd&#x27;s-components?" class="anchor">#</a></h3><p>If you need some features which should not be included in antd, try to extend antd&#x27;s component with <a href="https://gist.github.com/sebmarkbage/ef0bf1f338a7182b6775">HOC</a>. <a href="https://medium.com/@dan_abramov/mixins-are-dead-long-live-higher-order-components-94a0d2f9e750#.eeu8q01s1">more</a></p><h3 id="How-to-spell-Ant-Design-correctly?"><span>How to spell Ant Design correctly?</span><a href="#How-to-spell-Ant-Design-correctly?" class="anchor">#</a></h3><ul><li><p>✅ <strong>Ant Design</strong>: Capitalized with space, for the design language</p></li><li><p>✅ <strong>antd</strong>: all lowercase, for the React UI library</p></li></ul><p>Here are some typical wrong examples:</p><ul><li><p>❌ AntD</p></li><li><p>❌ antD</p></li><li><p>❌ Antd</p></li><li><p>❌ ant design</p></li><li><p>❌ AntDesign</p></li><li><p>❌ antdesign</p></li><li><p>❌ Antdesign</p></li></ul><h3 id="Do-you-guys-have-any-channel-for-donation,-like-PayPal-or-Alipay?"><span>Do you guys have any channel for donation, like PayPal or Alipay?</span><a href="#Do-you-guys-have-any-channel-for-donation,-like-PayPal-or-Alipay?" class="anchor">#</a></h3><p>Not yet.</p><h3 id="Why-not?"><span>Why not?</span><a href="#Why-not?" class="anchor">#</a></h3><p>Alibaba pays us.</p><hr/><h2 id="Errors-&amp;-Warnings"><span>Errors &amp; Warnings</span><a href="#Errors-&amp;-Warnings" class="anchor">#</a></h2><p>Here are some errors &amp; warnings that you may meet while using antd, but most of them are not bugs of antd.</p><h3 id="Adjacent-JSX-elements-must-be-wrapped-in-an-enclosing-tag"><span>Adjacent JSX elements must be wrapped in an enclosing tag</span><a href="#Adjacent-JSX-elements-must-be-wrapped-in-an-enclosing-tag" class="anchor">#</a></h3><p>An <a href="http://stackoverflow.com/questions/25034994/how-to-correctly-wrap-few-td-tags-for-jsxtransformer">answer from StackOverflow</a>, and please read <a href="http://facebook.github.io/react/docs/displaying-data.html#components-are-just-like-functions">React&#x27;s documentation</a>.</p><h3 id="React.createElement:-type-should-not-be-null,-undefined,-boolean,-or-number.-It-should-be-a-string-(for-DOM-elements)-or-a-ReactClass-(for-composite-components)"><span>React.createElement: type should not be null, undefined, boolean, or number. It should be a string (for DOM elements) or a ReactClass (for composite components)</span><a href="#React.createElement:-type-should-not-be-null,-undefined,-boolean,-or-number.-It-should-be-a-string-(for-DOM-elements)-or-a-ReactClass-(for-composite-components)" class="anchor">#</a></h3><p>Please make sure that you import <code>antd</code>&#x27;s components correctly. Read the corresponding documentation of the <code>antd</code>&#x27;s version which you use, and pay attention to typos.</p><h3 id="rm-is-not-recognized-as-an-internal-or-external-command"><span>rm is not recognized as an internal or external command</span><a href="#rm-is-not-recognized-as-an-internal-or-external-command" class="anchor">#</a></h3><p>Please read this <a href="https://github.com/ant-design/ant-design/issues/650#issuecomment-164966511">issue</a>, or try Linux/Unix.</p><h3 id="Failed-propType:-Invalid-prop-AAA-of-type-BBB-supplied-to-CCC,-expected-DDD.-Check-the-render-method-of-EEE."><span>Failed propType: Invalid prop <code>AAA</code> of type <code>BBB</code> supplied to <code>CCC</code>, expected <code>DDD</code>. Check the render method of <code>EEE</code>.</span><a href="#Failed-propType:-Invalid-prop-AAA-of-type-BBB-supplied-to-CCC,-expected-DDD.-Check-the-render-method-of-EEE." class="anchor">#</a></h3><p>Please read the corresponding documentation of the <code>antd</code>&#x27;s version which you use, and make sure that you pass values with correct type to <code>antd</code>&#x27;s components,</p><h3 id="Unknown-option:-xxx/package.json.presets"><span>Unknown option: xxx/package.json.presets</span><a href="#Unknown-option:-xxx/package.json.presets" class="anchor">#</a></h3><p>An <a href="http://stackoverflow.com/questions/33685365/unknown-option-babelrc-presets">answer from Stack Overflow</a>.</p><h3 id="Invariant-Violation:-findComponentRoot(...):-Unable-to-find-element."><span>Invariant Violation: findComponentRoot(...): Unable to find element.</span><a href="#Invariant-Violation:-findComponentRoot(...):-Unable-to-find-element." class="anchor">#</a></h3><p>You may import React twice. Set React &amp; ReactDOM as external, if you are using webpack, See <a href="https://github.com/ant-design/ant-design/issues/525">#525</a>. If you are using others (browserify, etc...), please read its documentation and find options which can set React &amp; ReactDOM as external.</p></section><section class="markdown api-container"></section></article></div></div><div class="ant-row"><div class="ant-col-xs-24 ant-col-sm-24 ant-col-md-24 ant-col-lg-18 ant-col-lg-offset-6 ant-col-xl-19 ant-col-xl-offset-5 ant-col-xxl-20 ant-col-xxl-offset-4"><section class="prev-next-nav"><a class="prev-page" href="/docs/react/i18n"><i class="anticon anticon-left footer-nav-icon-before"><svg viewBox="64 64 896 896" class="" data-icon="left" width="1em" height="1em" fill="currentColor" aria-hidden="true"><path d="M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 0 0 0 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281 360-281.1c3.8-3 6.1-7.7 6.1-12.6z"></path></svg></i>Internationalization<i class="anticon anticon-right footer-nav-icon-after"><svg viewBox="64 64 896 896" class="" data-icon="right" width="1em" height="1em" fill="currentColor" aria-hidden="true"><path d="M765.7 486.8L314.9 134.7A7.97 7.97 0 0 0 302 141v77.3c0 4.9 2.3 9.6 6.1 12.6l360 281.1-360 281.1c-3.9 3-6.1 7.7-6.1 12.6V883c0 6.7 7.7 10.4 12.9 6.3l450.8-352.1a31.96 31.96 0 0 0 0-50.4z"></path></svg></i></a><a class="next-page" href="/docs/react/contributing"><i class="anticon anticon-left footer-nav-icon-before"><svg viewBox="64 64 896 896" class="" data-icon="left" width="1em" height="1em" fill="currentColor" aria-hidden="true"><path d="M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 0 0 0 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281 360-281.1c3.8-3 6.1-7.7 6.1-12.6z"></path></svg></i>Contributing<i class="anticon anticon-right footer-nav-icon-after"><svg viewBox="64 64 896 896" class="" data-icon="right" width="1em" height="1em" fill="currentColor" aria-hidden="true"><path d="M765.7 486.8L314.9 134.7A7.97 7.97 0 0 0 302 141v77.3c0 4.9 2.3 9.6 6.1 12.6l360 281.1-360 281.1c-3.9 3-6.1 7.7-6.1 12.6V883c0 6.7 7.7 10.4 12.9 6.3l450.8-352.1a31.96 31.96 0 0 0 0-50.4z"></path></svg></i></a></section></div></div></div><footer id="footer"><div class="footer-wrap"><div class="ant-row"><div class="ant-col-xs-24 ant-col-sm-24 ant-col-md-6"><div class="footer-center"><h2><span>Resources</span></h2><div><a href="http://pro.ant.design">Ant Design Pro</a></div><div><a href="http://mobile.ant.design">Ant Design Mobile</a></div><div><a href="http://ng.ant.design">NG-ZORRO</a><span> - </span>Ant Design of Angular</div><div><a href="http://ng.mobile.ant.design">NG-ZORRO-MOBILE</a></div><div><a target="_blank " href="https://github.com/websemantics/awesome-ant-design"><span>Awesome Ant Design</span></a></div><div><span class="ant-badge"><a target="_blank" rel="noopener noreferrer" href="http://kitchen.alipay.com">Kitchen</a><span> - </span><span>Sketch Toolkit</span><sup data-show="true" class="ant-scroll-number ant-badge-dot" style="right:-3px;margin-top:0"></sup></span></div><div><a href="http://scaffold.ant.design">Scaffolds</a><span> - </span><span>Scaffold Market</span></div><div><a target="_blank" rel="noopener noreferrer" href="http://umijs.org/">Umi</a> - <span>React Application Framework</span></div><div><a target="_blank" rel="noopener noreferrer" href="https://github.com/dvajs/dva">dva</a> - <span>Data Flow Framework</span></div><div><a target="_blank" rel="noopener noreferrer" href="http://motion.ant.design">Ant Motion</a><span> - </span><span>Motion Solution</span></div><div><a target="_blank" rel="noopener noreferrer" href="http://library.ant.design/">Axure Library</a><span> - </span><span>Axure library</span></div><div><a target="_blank" rel="noopener noreferrer" href="http://ux.ant.design">Ant UX</a><span> - </span><span>Sitemap Template</span></div><div><a target="_blank " href="http://ant-design.gitee.io/"><span>China Mirror 🇨🇳</span></a></div></div></div><div class="ant-col-xs-24 ant-col-sm-24 ant-col-md-6"><div class="footer-center"><h2><span>Community</span></h2><div><a target="_blank" rel="noopener noreferrer" href="http://zhuanlan.zhihu.com/antdesign"><span>Zhihu</span></a></div><div><a target="_blank" rel="noopener noreferrer" href="http://medium.com/ant-design/">Medium</a></div><div><a target="_blank" rel="noopener noreferrer" href="http://twitter.com/antdesignui">Twitter</a></div><div><a target="_blank" rel="noopener noreferrer" href="http://zhuanlan.zhihu.com/xtech"><span>Experience Cloud Blog</span></a></div><div><a target="_blank" rel="noopener noreferrer" href="http://seeconf.alipay.com/">SEE Conf</a><span> - </span><span>Seeking Experience &amp; Engineering Conference</span></div><div><a target="_blank " href="/docs/spec/work-with-us"><span>Work with Us</span></a></div></div></div><div class="ant-col-xs-24 ant-col-sm-24 ant-col-md-6"><div class="footer-center"><h2><span>Help</span></h2><div><a target="_blank " href="https://github.com/ant-design/ant-design">GitHub</a></div><div><a href="/changelog"><span>Change Log</span></a></div><div><a target="_blank " href="https://www.yuque.com/ant-design/course"><span>Ant Design Practical Tutorial</span></a></div><div><a target="_blank" rel="noopener noreferrer" href="/docs/react/faq"><span>FAQ</span></a></div><div><a target="_blank" rel="noopener noreferrer" href="https://gitter.im/ant-design/ant-design"><span>Chat Room (中文)</span></a></div><div><a target="_blank" rel="noopener noreferrer" href="https://gitter.im/ant-design/ant-design-english"><span>Chat Room (English)</span></a></div><div><a target="_blank" rel="noopener noreferrer" href="http://new-issue.ant.design/"><span>Bug Report</span></a></div><div><a target="_blank" rel="noopener noreferrer" href="https://github.com/ant-design/ant-design/issues"><span>Issues</span></a></div><div><a target="_blank" rel="noopener noreferrer" href="http://stackoverflow.com/questions/tagged/antd"><span>StackOverflow</span></a></div><div><a target="_blank" rel="noopener noreferrer" href="https://segmentfault.com/t/antd"><span>SegmentFault</span></a></div></div></div><div class="ant-col-xs-24 ant-col-sm-24 ant-col-md-6"><div class="footer-center"><h2><img class="title-icon" src="https://gw.alipayobjects.com/zos/rmsportal/nBVXkrFdWHxbZlmMbsaH.svg" alt="AFX Cloud"/><span>More Products</span></h2><div><a target="_blank" rel="noopener noreferrer" href="https://yuque.com/"><span>YuQue</span></a><span> - </span><span>Write your document as a team</span></div><div><a target="_blank" rel="noopener noreferrer" href="https://yunfengdie.com/"><span>FengDie</span></a><span> - </span><span>Mobile web app builder</span></div><div><a target="_blank" rel="noopener noreferrer" href="https://antv.alipay.com/">AntV</a><span> - </span><span>Data Visualization</span></div><div><a target="_blank" rel="noopener noreferrer" href="https://eggjs.org/">Egg</a><span> - </span><span>Enterprise Node Framework</span></div><div><a target="_blank" rel="noopener noreferrer" href="http://xcloud.alipay.com/"><span>Ant Experience Cloud</span></a></div><div style="margin-top:20px"><div><div style="padding:4px;background:#fff;border-radius:2px;box-shadow:0 0 0 1px rgba(0,0,0,.1);display:inline-block;cursor:pointer"><div style="width:80px;height:16px;border-radius:2px;background:#1890ff"></div></div></div></div></div></div></div></div><div class="bottom-bar">Made with <span class="heart">❤</span> by<a target="_blank" rel="noopener noreferrer" href="https://xtech.antfin.com"><span>AFX</span></a></div></footer></div>
    </div>
    <script src="/common.js"></script>
    <script src="/index.js"></script>
    <!-- Global site tag (gtag.js) - Google Analytics -->
    <script async src="https://www.googletagmanager.com/gtag/js?id=UA-72788897-1"></script>
    <script>
    if (!location.port) {
      // Enable Google Analytics
      window.dataLayer = window.dataLayer || [];
      function gtag(){dataLayer.push(arguments);}
      gtag('js', new Date());
      gtag('config', 'UA-72788897-1');
    }
    </script>
    <!-- Hotjar Tracking Code for ant.design -->
    <script>
    (function(h,o,t,j,a,r){
      h.hj=h.hj||function(){(h.hj.q=h.hj.q||[]).push(arguments)};
      h._hjSettings={hjid:473408,hjsv:5};
      a=o.getElementsByTagName('head')[0];
      r=o.createElement('script');r.async=1;
      r.src=t+h._hjSettings.hjid+j+h._hjSettings.hjsv;
      a.appendChild(r);
    })(window,document,'//static.hotjar.com/c/hotjar-','.js?sv=');
    </script>
  </body>
</html>
